<!doctype html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="apple-mobile-web-app-capable" content="yes" />
    <meta name="apple-mobile-web-app-status-bar-style" content="black" />
    <meta name="format-detection" content="telephone=no, email=no" />
    <title>供灯</title>
    <script type="text/javascript" src="{MODULE_URL}public/deng/js/flexible.js"></script>
    <script type="text/javascript" src="{MODULE_URL}public/deng/js/pageLoading.js"></script>
    <link type="text/css" rel="stylesheet" href="{MODULE_URL}public/deng/css/indexLamp.css">
</head>
<body>
<div class="music running" >
    <audio id="bgmusic" src="http://baifo.b0.upaiyun.com/music/mercy.mp3" autoplay loop></audio>
</div>
<div class="musicSmall musicS1"></div>
<div class="musicSmall musicS2"></div>
<div class="musicSmall musicS3"></div>
<div class="eggHua eggHua_one"></div>
<div class="candle candle_one"></div>
<div class="pingan"></div>
<div class="eggHua eggHua_two"></div>
<div class="candle candle_two"></div>
<div class="buddha">
    <img src="{MODULE_URL}public/deng/images/safety.png" alt="佛像" />
</div>
<div class="lampAll">
    <div class="lighting"></div>
    {loop $list $item}
        <div class="lampBuddha">
            <img src="../attachment/{$item['image']}" alt="佛灯" />
            <span>{$item['name']}</span>
        </div>
    {/loop}
</div>
<div id="mask"></div>
<div class="lampTan">
    <span>随喜赞叹，您今天供灯圆满请做回向，积累功德消业障</span>
    <div class="lampA">
        <a href="" class="lampOk">确定</a>
        <a href="javaScript:;" class="lampCancel">取消</a>
    </div>
</div>
 {template 'baifocommon/nav'}
<script type="text/javascript" src="{MODULE_URL}public/deng/js/zepto.min.js"></script>
<script>
    $(function(){
        $(".music").on('tap',function(){
            if(!$(this).hasClass('off')){
                $(this).addClass('off');
                $(this).removeClass('running');
                $('audio').get(0).pause();
                $('.musicSmall').hide();

            }else{
                $(this).removeClass('off');
                $(this).addClass('running');
                $('audio').get(0).play();
                $('.musicSmall').show();
            }
        });
    });
</script>
<script>
    $(window).on('load',function(){
        $(function(){
            function timer(){
                $("#mask").show();
                $(".lampTan").show();
            }
            setTimeout(timer,3000);
        });

        $(".lampCancel").on('tap',function(){
            $("#mask").hide();
            $(".lampTan").hide();
        });

        $(".nav>li").on('tap', function(e){
            e.stopPropagation();
            var index = $(this).index();
            $(this).addClass('on').siblings().removeClass('on');

        });
        $(".dropA").on('tap',function(){
            if (!$('.dropdown').hasClass('downOn')) {
                $('.dropdown').addClass('downOn');
            }else{
                $('.dropdown').removeClass('downOn');
            }
        })
        $(document).on('tap', function(e){
            var obj = e.target;
            if (!$(obj).is('.dropdown, .dropdown *')) {
                $('.dropdown').removeClass('downOn');
            }
        });

    })
</script>
</body>
</html>